<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<ui:composition template="/WEB-INF/template/mainTemplate.xhtml"
                xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:of="http://omnifaces.org/functions">
    <ui:define name="content">
        <div>
            <h1>Unexpected Error</h1>
        </div>
        <ul>
            <li>Date/time: #{of:formatDate(now, 'yyyy-MM-dd HH:mm:ss')}</li>
            <li>User agent: #{header['user-agent']}</li>
            <li>User IP: #{request.remoteAddr}</li>
            <li>Request URI: <a
                    href="#{requestScope['javax.servlet.error.request_uri']}">#{requestScope['javax.servlet.error.request_uri']}</a>
            </li>
            <li>Ajax request: #{facesContext.partialViewContext.ajaxRequest ? 'Yes' : 'No'}</li>
            <li>Status code: #{requestScope['javax.servlet.error.status_code']}</li>
            <li>Exception type: #{requestScope['javax.servlet.error.exception_type']}</li>
            <li>Exception message: #{requestScope['javax.servlet.error.message']}</li>
            <li>Stack trace:
                <pre><code>#{of:printStackTrace(requestScope['javax.servlet.error.exception'])}</code></pre>
            </li>
        </ul>
    </ui:define>
</ui:composition>
</html>

